-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missing inputs #1212
Missing inputs #1212
Conversation
except when all inputs have multivalued wildcards and all outputs exist
735da2e
to
a2387c3
Compare
|
||
def test_cbmi007_all_multi_wildcards_some_outputs(dash_duo): | ||
# same as above (cbmi006) but multi-output, some outputs present some missing. | ||
# Again we DO NOT fire the callback |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a case I didn't think of until writing related tests, but I think it makes sense, because if there's any missing output and no inputs, that output will probably show up when the inputs do.
This is basically the same as test cbmi004
just for the case when all the inputs have multi-value wildcards so we do try to fire the callback, and we need to bail out at a later step when we collect all the outputs.
The first 4 of these tests (modified for the changed internals) pass when run against Dash v1.10 - so this clears the regression as far as I understand it. The other 5 tests all use wildcards so are not relevant to v1.10. cc @chriddyp @Marc-Andre-Rivet |
dash-renderer/src/actions/index.js
Outdated
if (e instanceof ReferenceError) { | ||
errors.push(e); | ||
return null; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering what would be required to be able to write this (and https://github.com/plotly/dash/pull/1212/files#diff-15692ba768eeab56e95aa409ab7c19b7R279) so that we don't use exceptions as flow control.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't use exceptions as flow control
yeah I suppose that's cleaner now that they aren't always errors -> b44bd54
dash-renderer/src/actions/index.js
Outdated
// Wildcard reference errors mention a list of wildcard specs logged | ||
// TODO: unwrapped list of wildcard ids? | ||
// eslint-disable-next-line no-console | ||
console.log(paths.objs); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this meant to be console.error
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixes #1200 - regression in Dash 1.11 with callbacks that have outputs but no inputs.
optionals
CHANGELOG.md